<!DOCTYPE html>
<html class="no-js">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title></title>
    <meta name="description" content="">
    <meta name="viewport" content="width=device-width">

    <link rel="stylesheet" href="css/bootstrap.min.css">
    <style>
      body {
        padding-top: 60px;
        padding-bottom: 40px;
      }
    </style>
    <link rel="stylesheet" href="css/bootstrap-responsive.min.css">
    <link rel="stylesheet" href="css/main.css">

    <!--[if lt IE 9]>
      <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
      <script>window.html5 || document.write('<script src="js/vendor/html5shiv.js"><\/script>')</script>
    <![endif]-->
  </head>
  <body>
    <script type="text/javascript">
      window.data = <%= data.to_json %>;
    </script>
    <div class="navbar navbar-inverse navbar-fixed-top">
      <div class="navbar-inner">
        <div class="container">
          <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </a>
          <a class="brand" href="#">Profit Charts</a>
        </div>
      </div>
    </div>
    <div class="tabbable tabs-left">
      <ul id="key_links" class="nav nav-tabs">
        <% data.keys.each_with_index do |key, index| %>
          <% first = index == 0 %>
          <li class="<%= 'active' if first %>"><a href="#tab_<%= key %>" id="<%= key %>" data-toggle="tab"><%= key %></a></li>
        <% end %>
      </ul>
      <div class="tab-content">
        <% data.keys.each_with_index do |key, index| %>
          <% first = index == 0 %>
          <div class="tab-pane <%= 'active' if first %>" id="tab_<%= key %>">
            <canvas id="chart_<%= key %>" width="1200" height="400"></canvas>
          </div>
        <% end %>
      </div>
    </div>

    <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.js"></script>
    <script>window.jQuery || document.write('<script src="js/vendor/jquery-1.9.1.js"><\/script>')</script>

    <script src="js/vendor/bootstrap.min.js"></script>
    <script src="js/vendor/Chart.js"></script>
    <script src="js/main.js"></script>
  </body>
</html>
